/*
 * @Description: voxel_filter.hpp
 * @Author: Sang Hao
 * @Date: 2021-09-15 17:08:57
 * @LastEditTime: 2021-11-08 19:35:27
 * @LastEditors: Sang Hao
 */
#ifndef LIDAR_SLAM_MODELS_CLOUD_FILTER_VOXEL_FILTER_HPP_
#define LIDAR_SLAM_MODELS_CLOUD_FILTER_VOXEL_FILTER_HPP_

#include <pcl/filters/passthrough.h>
#include <yaml-cpp/yaml.h>
#include "lidar_slam/models/cloud_filter/cloud_filter_interface.hpp"


namespace lidar_slam {
class PassFilter: public CloudFilterInterface {
private:
	/* data */
	pcl::PassThrough<CloudData::POINT> pass_through_filter_;
	
private:
	bool SetFilterParam(std::string field_name, float limit_min, float limit_max);

public:
	PassFilter(const YAML::Node& config_node);
	PassFilter(std::string field_name, float limit_min, float limit_max);

	bool Filter(const CloudData::CLOUD_PTR& input_cloud_ptr, 
		CloudData::CLOUD_PTR& filter_cloud_ptr) override;
};
}

#endif